package com.njtoyo.taxi.admin.service.business;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.njtoyo.taxi.admin.mapper.master.entity.ElderlyDeviceManage;
import com.njtoyo.taxi.admin.rest.pojo.dto.ElderlyDeviceAddDto;
import com.njtoyo.taxi.admin.rest.pojo.dto.ElderlyDeviceFunctionUpdateDto;
import com.njtoyo.taxi.admin.rest.presenter.ElderlyDeviceCallCardNumPresenter;
import com.njtoyo.taxi.admin.rest.presenter.business.ElderlyDeviceManagePresenter;
import com.njtoyo.taxi.admin.rest.wrapper.business.device.ElderlyDeviceExportWrapper;
import com.njtoyo.taxi.admin.rest.wrapper.business.device.ElderlyDeviceQueryWrapper;
import com.njtoyo.taxi.entity.backend.AdminUser;
import com.taxi.entity.common.RestResult;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.util.List;

public interface ElderlyDeviceService {
    RestResult<Boolean> addNew(AdminUser adminUser,ElderlyDeviceAddDto dto);

    RestResult<ElderlyDeviceManage> getElderlyDeviceByDeviceSerialNumber(String  deviceSerialNumber);

    RestResult<Boolean> enableElderlyByDevice(ElderlyDeviceAddDto dto);

    RestResult<Boolean> enableElderlyByBackend(ElderlyDeviceAddDto dto);

    RestResult<ElderlyDeviceManage> getInfo(String  deviceSerialNumber);

    RestResult<Boolean> editElderlyDevice(AdminUser adminUser,ElderlyDeviceAddDto dto);

    RestResult<Boolean> updateElderlyDeviceFunction(ElderlyDeviceFunctionUpdateDto dto);

    RestResult<Page<ElderlyDeviceManagePresenter>> getList(AdminUser adminUser, ElderlyDeviceQueryWrapper wrapper);

    RestResult<List<ElderlyDeviceCallCardNumPresenter>> getCallCardNum(String deviceSerialNumber);

    void exportElderlyDeviceList(AdminUser adminUser, ElderlyDeviceExportWrapper wrapper, HttpServletResponse response) throws IOException;

    RestResult<ElderlyDeviceCallCardNumPresenter> getAllCallCardNumPresenter();

    RestResult<List<ElderlyDeviceManagePresenter>> getListByCantonId(Integer cantonId);
}
